// Code generated by mockery v2.20.0. DO NOT EDIT.

package mocks

import (
	context "context"
	"gitverse.ru/synapse/kubelatte/pkg/api/v1alpha1"

	mock "github.com/stretchr/testify/mock"
	v1 "k8s.io/apimachinery/pkg/apis/meta/v1"

	watch "k8s.io/apimachinery/pkg/watch"
)

// TemplateInterface is an autogenerated mock type for the TemplateInterface type
type TemplateInterface struct {
	mock.Mock
}

// Create provides a mock function with given fields: ctx, template
func (_m *TemplateInterface) Create(ctx context.Context, template *v1alpha1.Template) (*v1alpha1.Template, error) {
	ret := _m.Called(ctx, template)

	var r0 *v1alpha1.Template
	var r1 error
	if rf, ok := ret.Get(0).(func(context.Context, *v1alpha1.Template) (*v1alpha1.Template, error)); ok {
		return rf(ctx, template)
	}
	if rf, ok := ret.Get(0).(func(context.Context, *v1alpha1.Template) *v1alpha1.Template); ok {
		r0 = rf(ctx, template)
	} else {
		if ret.Get(0) != nil {
			r0 = ret.Get(0).(*v1alpha1.Template)
		}
	}

	if rf, ok := ret.Get(1).(func(context.Context, *v1alpha1.Template) error); ok {
		r1 = rf(ctx, template)
	} else {
		r1 = ret.Error(1)
	}

	return r0, r1
}

// Delete provides a mock function with given fields: ctx, name, opts
func (_m *TemplateInterface) Delete(ctx context.Context, name string, opts v1.DeleteOptions) error {
	ret := _m.Called(ctx, name, opts)

	var r0 error
	if rf, ok := ret.Get(0).(func(context.Context, string, v1.DeleteOptions) error); ok {
		r0 = rf(ctx, name, opts)
	} else {
		r0 = ret.Error(0)
	}

	return r0
}

// Get provides a mock function with given fields: ctx, name, options
func (_m *TemplateInterface) Get(ctx context.Context, name string, options v1.GetOptions) (*v1alpha1.Template, error) {
	ret := _m.Called(ctx, name, options)

	var r0 *v1alpha1.Template
	var r1 error
	if rf, ok := ret.Get(0).(func(context.Context, string, v1.GetOptions) (*v1alpha1.Template, error)); ok {
		return rf(ctx, name, options)
	}
	if rf, ok := ret.Get(0).(func(context.Context, string, v1.GetOptions) *v1alpha1.Template); ok {
		r0 = rf(ctx, name, options)
	} else {
		if ret.Get(0) != nil {
			r0 = ret.Get(0).(*v1alpha1.Template)
		}
	}

	if rf, ok := ret.Get(1).(func(context.Context, string, v1.GetOptions) error); ok {
		r1 = rf(ctx, name, options)
	} else {
		r1 = ret.Error(1)
	}

	return r0, r1
}

// List provides a mock function with given fields: ctx, opts
func (_m *TemplateInterface) List(ctx context.Context, opts v1.ListOptions) (*v1alpha1.TemplateList, error) {
	ret := _m.Called(ctx, opts)

	var r0 *v1alpha1.TemplateList
	var r1 error
	if rf, ok := ret.Get(0).(func(context.Context, v1.ListOptions) (*v1alpha1.TemplateList, error)); ok {
		return rf(ctx, opts)
	}
	if rf, ok := ret.Get(0).(func(context.Context, v1.ListOptions) *v1alpha1.TemplateList); ok {
		r0 = rf(ctx, opts)
	} else {
		if ret.Get(0) != nil {
			r0 = ret.Get(0).(*v1alpha1.TemplateList)
		}
	}

	if rf, ok := ret.Get(1).(func(context.Context, v1.ListOptions) error); ok {
		r1 = rf(ctx, opts)
	} else {
		r1 = ret.Error(1)
	}

	return r0, r1
}

// Update provides a mock function with given fields: ctx, template, opts
func (_m *TemplateInterface) Update(ctx context.Context, template *v1alpha1.Template, opts v1.UpdateOptions) (*v1alpha1.Template, error) {
	ret := _m.Called(ctx, template, opts)

	var r0 *v1alpha1.Template
	var r1 error
	if rf, ok := ret.Get(0).(func(context.Context, *v1alpha1.Template, v1.UpdateOptions) (*v1alpha1.Template, error)); ok {
		return rf(ctx, template, opts)
	}
	if rf, ok := ret.Get(0).(func(context.Context, *v1alpha1.Template, v1.UpdateOptions) *v1alpha1.Template); ok {
		r0 = rf(ctx, template, opts)
	} else {
		if ret.Get(0) != nil {
			r0 = ret.Get(0).(*v1alpha1.Template)
		}
	}

	if rf, ok := ret.Get(1).(func(context.Context, *v1alpha1.Template, v1.UpdateOptions) error); ok {
		r1 = rf(ctx, template, opts)
	} else {
		r1 = ret.Error(1)
	}

	return r0, r1
}

// UpdateStatus provides a mock function with given fields: ctx, hostEntry, opts
func (_m *TemplateInterface) UpdateStatus(ctx context.Context, hostEntry *v1alpha1.Template, opts v1.UpdateOptions) (*v1alpha1.Template, error) {
	ret := _m.Called(ctx, hostEntry, opts)

	var r0 *v1alpha1.Template
	var r1 error
	if rf, ok := ret.Get(0).(func(context.Context, *v1alpha1.Template, v1.UpdateOptions) (*v1alpha1.Template, error)); ok {
		return rf(ctx, hostEntry, opts)
	}
	if rf, ok := ret.Get(0).(func(context.Context, *v1alpha1.Template, v1.UpdateOptions) *v1alpha1.Template); ok {
		r0 = rf(ctx, hostEntry, opts)
	} else {
		if ret.Get(0) != nil {
			r0 = ret.Get(0).(*v1alpha1.Template)
		}
	}

	if rf, ok := ret.Get(1).(func(context.Context, *v1alpha1.Template, v1.UpdateOptions) error); ok {
		r1 = rf(ctx, hostEntry, opts)
	} else {
		r1 = ret.Error(1)
	}

	return r0, r1
}

// Watch provides a mock function with given fields: ctx, opts
func (_m *TemplateInterface) Watch(ctx context.Context, opts v1.ListOptions) (watch.Interface, error) {
	ret := _m.Called(ctx, opts)

	var r0 watch.Interface
	var r1 error
	if rf, ok := ret.Get(0).(func(context.Context, v1.ListOptions) (watch.Interface, error)); ok {
		return rf(ctx, opts)
	}
	if rf, ok := ret.Get(0).(func(context.Context, v1.ListOptions) watch.Interface); ok {
		r0 = rf(ctx, opts)
	} else {
		if ret.Get(0) != nil {
			r0 = ret.Get(0).(watch.Interface)
		}
	}

	if rf, ok := ret.Get(1).(func(context.Context, v1.ListOptions) error); ok {
		r1 = rf(ctx, opts)
	} else {
		r1 = ret.Error(1)
	}

	return r0, r1
}

type mockConstructorTestingTNewTemplateInterface interface {
	mock.TestingT
	Cleanup(func())
}

// NewTemplateInterface creates a new instance of TemplateInterface. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations.
func NewTemplateInterface(t mockConstructorTestingTNewTemplateInterface) *TemplateInterface {
	mock := &TemplateInterface{}
	mock.Mock.Test(t)

	t.Cleanup(func() { mock.AssertExpectations(t) })

	return mock
}
